Optimal. Leaf size=27 \[ -\frac {\text {ArcCos}(a x)}{x}+a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {4724, 272, 65,
214} \begin {gather*} a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right )-\frac {\text {ArcCos}(a x)}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 65
Rule 214
Rule 272
Rule 4724
Rubi steps
\begin {align*} \int \frac {\cos ^{-1}(a x)}{x^2} \, dx &=-\frac {\cos ^{-1}(a x)}{x}-a \int \frac {1}{x \sqrt {1-a^2 x^2}} \, dx\\ &=-\frac {\cos ^{-1}(a x)}{x}-\frac {1}{2} a \text {Subst}\left (\int \frac {1}{x \sqrt {1-a^2 x}} \, dx,x,x^2\right )\\ &=-\frac {\cos ^{-1}(a x)}{x}+\frac {\text {Subst}\left (\int \frac {1}{\frac {1}{a^2}-\frac {x^2}{a^2}} \, dx,x,\sqrt {1-a^2 x^2}\right )}{a}\\ &=-\frac {\cos ^{-1}(a x)}{x}+a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 34, normalized size = 1.26 \begin {gather*} -\frac {\text {ArcCos}(a x)}{x}-a \log (x)+a \log \left (1+\sqrt {1-a^2 x^2}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.01, size = 29, normalized size = 1.07
method | result | size |
derivativedivides | \(a \left (-\frac {\arccos \left (a x \right )}{a x}+\arctanh \left (\frac {1}{\sqrt {-a^{2} x^{2}+1}}\right )\right )\) | \(29\) |
default | \(a \left (-\frac {\arccos \left (a x \right )}{a x}+\arctanh \left (\frac {1}{\sqrt {-a^{2} x^{2}+1}}\right )\right )\) | \(29\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.49, size = 38, normalized size = 1.41 \begin {gather*} a \log \left (\frac {2 \, \sqrt {-a^{2} x^{2} + 1}}{{\left | x \right |}} + \frac {2}{{\left | x \right |}}\right ) - \frac {\arccos \left (a x\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 82 vs.
\(2 (25) = 50\).
time = 2.67, size = 82, normalized size = 3.04 \begin {gather*} \frac {a x \log \left (\sqrt {-a^{2} x^{2} + 1} + 1\right ) - a x \log \left (\sqrt {-a^{2} x^{2} + 1} - 1\right ) + 2 \, {\left (x - 1\right )} \arccos \left (a x\right ) - 2 \, x \arctan \left (\frac {\sqrt {-a^{2} x^{2} + 1} a x}{a^{2} x^{2} - 1}\right )}{2 \, x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [C] Result contains complex when optimal does not.
time = 1.00, size = 34, normalized size = 1.26 \begin {gather*} - a \left (\begin {cases} - \operatorname {acosh}{\left (\frac {1}{a x} \right )} & \text {for}\: \frac {1}{\left |{a^{2} x^{2}}\right |} > 1 \\i \operatorname {asin}{\left (\frac {1}{a x} \right )} & \text {otherwise} \end {cases}\right ) - \frac {\operatorname {acos}{\left (a x \right )}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.43, size = 48, normalized size = 1.78 \begin {gather*} \frac {1}{2} \, a {\left (\log \left (\sqrt {-a^{2} x^{2} + 1} + 1\right ) - \log \left (-\sqrt {-a^{2} x^{2} + 1} + 1\right )\right )} - \frac {\arccos \left (a x\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.02, size = 25, normalized size = 0.93 \begin {gather*} a\,\mathrm {atanh}\left (\frac {1}{\sqrt {1-a^2\,x^2}}\right )-\frac {\mathrm {acos}\left (a\,x\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________